package cars

import (
	"time"
)

type CarsStruct struct {
	Id                int       `json:"id" gorm:"type:int(11) unsigned auto_increment; NOT NULL; primary_key"`
	TripartiteType    int       `json:"tripartite_type" gorm:"type:tinyint(11); NOT NULL; COMMENT:'三方类型 1小强 2泊安飞 3钉钉'"`
	TripartiteVoucher string    `json:"tripartite_voucher" gorm:"type:varchar(255); COMMENT:'三方凭证1. 钉钉临时停车时, 存所属企业'"`
	MemberId          int       `json:"member_id" gorm:"type:int(11); NOT NULL; COMMENT:'member表id'"`
	Mobile            string    `json:"mobile" gorm:"type:varchar(255); NOT NULL; COMMENT:'手机号'"`
	CarNumber         string    `json:"car_number" gorm:"type:varchar(20); NOT NULL; COMMENT:'车牌号'"`
	CarInfo           string    `json:"car_info" gorm:"type:varchar(50);  COMMENT:'车辆信息'"`
	CarType           int       `json:"car_type" gorm:"type:tinyint(1); COMMENT:'车型 1: 小型车 2: 中型车 3: 大型车 4: 其 他'"`
	CarNoColor        int       `json:"car_no_color" gorm:"type:tinyint(1); COMMENT:'车牌颜色 1-蓝牌 3-黄牌 6-绿牌 7-白牌 8-黑牌'"`
	From              int       `json:"from" gorm:"type:tinyint(1); COMMENT:'来源类型'"`
	BindType          int       `json:"bind_type" gorm:"type:tinyint(1); COMMENT:'绑定类型 1永久 2临时'"`
	StartTime         int       `json:"start_time" gorm:"type:int(11); COMMENT:'绑定开始时间'"`
	EndTime           int       `json:"end_time" gorm:"type:int(11); COMMENT:'绑定结束时间'"`
	CreatedAt         time.Time `json:"created_at" gorm:"type:datetime"`
	UpdatedAt         time.Time `json:"updated_at" gorm:"type:datetime"`
}

func (c *CarsStruct) TableName() string {
	return "cars"
}
